Compression/decompression accelerator protocol for software/hardware integration

ABSTRACT

Embodiments relate to providing a data stream interface for offloading the inflation/deflation processing of data to a stateless compression accelerator. An aspect includes transmitting a request to inflate or deflate a data stream to a compression accelerator. The request may include references to an input buffer for storing input data from the data stream, an output buffer for storing processed input data, and a state data control block for storing a stream state. The stream state is provided to the compression accelerator to continue processing the data stream responsive to the request being a subsequent request. The compression accelerator is instructed to store a current stream state in the state data control block responsive to the request being a non-final request. Accordingly, the current stream state is received from the compression accelerator responsive to the request being a non-final request. The processed input data is received from the compression accelerator.

DOMESTIC PRIORITY

This application is a continuation of U.S. patent application Ser. No.13/834,972, filed Mar. 15, 2013, the disclosure of which is incorporatedby reference herein in its entirety.

BACKGROUND

The present invention relates generally to storage management, and morespecifically, to providing a data stream interface for offloading theinflation/deflation processing of data to a stateless compressionaccelerator.

With the proliferation of computers and electronic devices, the demandfor more data storage space grows at an unprecedented pace. Accordingly,real time data compression algorithms are typically used to realize amore efficient use of finite storage space through the compression ofdata.

Contemporary applications may require that compression services use thezlib compression library to implement a DEFLATE compression algorithm tocompress data and conserve storage space. DEFLATE is a typical losslessdata compression algorithm that is specified in Requests for Comments(RFC) 1951. The zlib compression library generally provides a datastream based interface for inflating/deflating data. A typical datastream interface allows an application to break up input data to beinflated/deflated in arbitrary ways across multiple requests andprovides arbitrary sized output buffers to hold the results of theinflate/deflate operation.

SUMMARY

According to an embodiment of the present invention, a method forproviding a data stream interface for offloading the inflation/deflationprocessing of data to a stateless compression accelerator is provided.The method includes transmitting a request to inflate or deflate a datastream to a compression accelerator. The request may include referencesto an input buffer for storing input data from the data stream, anoutput buffer for storing processed input data, and a state data controlblock for storing a stream state. The stream state is provided to thecompression accelerator to continue processing the data streamresponsive to the request being a subsequent request. According toembodiments, the compression accelerator is instructed to store acurrent stream state in the state data control block responsive to therequest being a non-final request according to embodiments. Accordingly,the current stream state is received from the compression acceleratorresponsive to the request being a non-final request. The processed inputdata is received from the compression accelerator according toembodiments.

According to another embodiment of the present invention, a system forproviding a data stream interface for offloading the inflation/deflationprocessing of data to a stateless compression accelerator is provided.The system includes a computer processor and logic executable by thecomputer processor. The logic is configured to implement a method. Themethod includes transmitting a request to inflate or deflate a datastream to a compression accelerator. The request may include referencesto an input buffer for storing input data from the data stream, anoutput buffer for storing processed input data, and a state data controlblock for storing a stream state. The stream state is provided to thecompression accelerator to continue processing the data streamresponsive to the request being a subsequent request. According toembodiments, the compression accelerator is instructed to store acurrent stream state in the state data control block responsive to therequest being a non-final request according to embodiments. Accordingly,the current stream state is received from the compression acceleratorresponsive to the request being a non-final request. The processed inputdata is received from the compression accelerator according toembodiments.

According to a further embodiment of the present invention, a computerprogram product for providing a data stream interface for offloading theinflation/deflation processing of data to a stateless compressionaccelerator is provided. The computer program product includes a storagemedium having computer-readable program code embodied thereon, whichwhen executed by a computer processor, causes the computer processor toimplement a method. The method includes transmitting a request toinflate or deflate a data stream to a compression accelerator. Therequest may include references to an input buffer for storing input datafrom the data stream, an output buffer for storing processed input data,and a state data control block for storing a stream state. The streamstate is provided to the compression accelerator to continue processingthe data stream responsive to the request being a subsequent request.According to embodiments, the compression accelerator is instructed tostore a current stream state in the state data control block responsiveto the request being a non-final request according to embodiments.Accordingly, the current stream state is received from the compressionaccelerator responsive to the request being a non-final request. Theprocessed input data is received from the compression acceleratoraccording to embodiments

Additional features and advantages are realized through the techniquesof the present invention. Other embodiments and aspects of the inventionare described in detail herein and are considered a part of the claimedinvention. For a better understanding of the invention with theadvantages and the features, refer to the description and to thedrawings.

BRIEF DESCRIPTION OF THE SEVERAL VIEWS OF THE DRAWINGS

The subject matter which is regarded as the invention is particularlypointed out and distinctly claimed in the claims at the conclusion ofthe specification. The forgoing and other features, and advantages ofthe invention are apparent from the following detailed description takenin conjunction with the accompanying drawings in which:

FIG. 1 depicts a block diagram of a computer system according to anembodiment;

FIG. 2 depicts a block diagram of a host system and a compressionaccelerator of an embodiment;

FIG. 3 depicts a flow diagram of a process for managing the state of adata stream in a data stream interface according to an embodiment;

FIG. 4 depicts a flow diagram of a process for buffer matching accordingto an embodiment;

FIG. 5 depicts a flow diagram of process for handling overflow dataduring deflate processing according to an embodiment;

FIG. 6 depicts a flow diagram of a process for handling overflow dataduring inflate processing according to an embodiment; and

FIG. 7 depicts a diagrammatic representation of a dictionary for a nextrequest according to an embodiment.

DETAILED DESCRIPTION

Embodiments disclosed herein are directed to providing a data streaminterface for offloading the inflation/deflation processing of data to astateless compression accelerator. Embodiments provide the data streaminterface between the stateless compression accelerator and a hostdriver that is compatible with a zlib compression library toinflate/deflate an input data stream.

According to embodiments disclosed herein, when the compressionaccelerator completes a request for a data stream under the direction ofthe host driver, the compression accelerator returns to the host driverall information necessary to resume the data stream on the next request.No information about the stream is maintained in the compressionaccelerator once it completes a request for that stream. The host driverof an embodiment maintains this returned information as a state of thestream for the life of the stream. Accordingly, on the next request forthe stream, the host driver passes the state of the stream back to thecompression accelerator so that the compression accelerator can restoreits internal structures to continue processing the stream.

According to another aspect of embodiments disclosed herein, arelationship between an amount of data processed in a request from anapplication's input buffer and the amount of data returned in theapplication's output buffer is monitored. Accordingly, responsive to theoutput buffer being completely full on return from an inflate/deflaterequest, the application assumes that not all of the input buffer hasbeen processed and would make a new request with the same input bufferwith new output buffer space. However, responsive to the output bufferbeing not completely full on return from the inflate/deflate request,the application assumes that all data of the input buffer has beenprocessed and submits a subsequent request containing the next set ofdata in the stream to be inflated/deflated.

A compression accelerator may implement a DEFLATE compressed data formatas specified by Requests for Comments (RFC) 1951. DEFLATE is a widelyused approach in data compression. However, DEFLATE may be centralprocessing unit (CPU) intensive. Therefore, embodiments disclosed hereinoffload the processing from a general purpose CPU to a special purposeaccelerator to process the CPU intensive aspects of the DEFLATEalgorithm. A compression accelerator provides this offload capability.The compression accelerator is attached to one or more host systemsthrough a data bus. On the host system side, the interactions with thecompression accelerator are controlled by host driver software. Thecompression accelerator accepts work requests from the host systems todeflate (i.e., compress) or inflate (i.e., uncompress) a block of data.The compression accelerator processes one of these work requests at atime. Once the compression accelerator completes a work request, nostate about that work requests is kept on the compression accelerator.It is important that the compression accelerator have this statelesscharacteristic so there can be no leakage of information across requestswhich could be coming from different applications on a host system orfrom different host systems.

To maximize the value of the compression accelerator, applicationsrunning on the host system may take advantage of the compressionaccelerator with little or no code changes. Many applications requiringcompression services use the zlib compression library which implementsthe DEFLATE compression in software. Therefore, according to anembodiment, a zlib compatible interface is provided to allow hostapplications to exploit the compression accelerator. The zlibcompression library provides a data stream based interface forinflating/deflating data. The data stream interface allows anapplication to break up the input data to be inflated/deflated inarbitrary ways across multiple requests and provides arbitrary sizedoutput buffers to hold the results of the inflate/deflate operation. Theapplication level interfaces for exploiting the compression acceleratormust also support this stream based approach.

Accordingly, embodiments disclosed herein provide a data streaminterface for inflating/deflating data that can offload processing to astateless compression accelerator. Embodiments allow the data to beinflated/deflated to be broken up across an arbitrary number of requeststo the compression accelerator with no state kept between requests bythe compression accelerator. Further, embodiments match the amount ofinput data processed for one request to the amount of output bufferspace provided by the application. Additionally, embodiments overcomeissues arising from the fact that data compressed in the DEFLATE formatis a bit string but application input and output buffers are bytealigned.

Referring now to FIG. 1, a block diagram of a computer system 10suitable for providing a data stream interface for offloading theinflation/deflation processing of data to a stateless compressionaccelerator according to exemplary embodiments is shown. Computer system10 is only one example of a computer system and is not intended tosuggest any limitation as to the scope of use or functionality ofembodiments described herein. Regardless, computer system 10 is capableof being implemented and/or performing any of the functionality setforth hereinabove.

Computer system 10 is operational with numerous other general purpose orspecial purpose computing system environments or configurations.Examples of well-known computing systems, environments, and/orconfigurations that may be suitable for use with computer system 10include, but are not limited to, personal computer systems, servercomputer systems, thin clients, thick clients, cellular telephones,handheld or laptop devices, multiprocessor systems, microprocessor-basedsystems, set top boxes, programmable consumer electronics, network PCs,minicomputer systems, mainframe computer systems, and distributed cloudcomputing environments that include any of the above systems or devices,and the like.

Computer system 10 may be described in the general context of computersystem-executable instructions, such as program modules, being executedby the computer system 10. Generally, program modules may includeroutines, programs, objects, components, logic, data structures, and soon that perform particular tasks or implement particular abstract datatypes. Computer system 10 may be practiced in distributed cloudcomputing environments where tasks are performed by remote processingdevices that are linked through a communications network. In adistributed computing environment, program modules may be located inboth local and remote computer system storage media including memorystorage devices.

As shown in FIG. 1, computer system 10 is shown in the form of ageneral-purpose computing device, also referred to as a processingdevice. The components of computer system may include, but are notlimited to, one or more processors or processing units 16, a systemmemory 28, and a bus 18 that couples various system components includingsystem memory 28 to processor 16.

Bus 18 represents one or more of any of several types of bus structures,including a memory bus or memory controller, a peripheral bus, anaccelerated graphics port, and a processor or local bus using any of avariety of bus architectures. By way of example, and not limitation,such architectures include Industry Standard Architecture (ISA) bus,Micro Channel Architecture (MCA) bus, Enhanced ISA (EISA) bus, VideoElectronics Standards Association (VESA) local bus, and PeripheralComponent Interconnects (PCI) bus.

Computer system 10 may include a variety of computer system readablemedia. Such media may be any available media that is accessible bycomputer system/server 10, and it includes both volatile andnon-volatile media, removable and non-removable media.

System memory 28 can include computer system readable media in the formof volatile memory, such as random access memory (RAM) 30 and/or cachememory 32. Computer system 10 may further include otherremovable/non-removable, volatile/non-volatile computer system storagemedia. By way of example only, storage system 34 can be provided forreading from and writing to a non-removable, non-volatile magnetic media(not shown and typically called a “hard drive”). Although not shown, amagnetic disk drive for reading from and writing to a removable,non-volatile magnetic disk (e.g., a “floppy disk”), and an optical diskdrive for reading from or writing to a removable, non-volatile opticaldisk such as a CD-ROM, DVD-ROM or other optical media can be provided.In such instances, each can be connected to bus 18 by one or more datamedia interfaces. As will be further depicted and described below,memory 28 may include at least one program product having a set (e.g.,at least one) of program modules that are configured to carry out thefunctions of embodiments of the disclosure.

Program/utility 40, having a set (at least one) of program modules 42,may be stored in memory 28 by way of example, and not limitation, aswell as an operating system, one or more application programs, otherprogram modules, and program data. Each of the operating system, one ormore application programs, other program modules, and program data orsome combination thereof, may include an implementation of a networkingenvironment. Program modules 42 generally carry out the functions and/ormethodologies of embodiments of the invention as described herein.

Computer system 10 may also communicate with one or more externaldevices 14 such as a keyboard, a pointing device, a display 24, etc.;one or more devices that enable a user to interact with computersystem/server 10; and/or any devices (e.g., network card, modem, etc.)that enable computer system/server 10 to communicate with one or moreother computing devices. Such communication can occur via Input/Output(I/O) interfaces 22. Still yet, computer system 10 can communicate withone or more networks such as a local area network (LAN), a general widearea network (WAN), and/or a public network (e.g., the Internet) vianetwork adapter 20. As depicted, network adapter 20 communicates withthe other components of computer system 10 via bus 18. It should beunderstood that although not shown, other hardware and/or softwarecomponents could be used in conjunction with computer system 10.Examples include, but are not limited to: microcode, device drivers,redundant processing units, external disk drive arrays, RAID systems,tape drives, and data archival storage systems, etc.

With reference to FIG. 2, a block diagram of a host system 200 and acompression accelerator 210 of an embodiment are generally shown.According to an embodiment, the host system 200 and the compressionaccelerator 210 may be implemented using the processing unit 16 incombination with the other components of the computer system 10described in FIG. 1.

The host system 200 of an embodiment may be connected to the compressionaccelerator 210. According to an embodiment, the compression accelerator210 may be shared among multiple host systems, but for simplicity onlyone host is shown in FIG. 2. The interaction between the compressionaccelerator 210 and the host system 200 may be controlled by a hostdriver 220 according to an embodiment. The host driver 220 of anembodiment may provide one or more application compression interfaces230, which are compatible with a zlib compression library.

To inflate or deflate a stream of data, an application 240 may make oneor more request calls to the compression interface 230 of the hostdriver 220. On each request call, the application 240 of an embodimentmay supply an input buffer 250 with the data to be processed and anoutput buffer 260 where the processed data results may be stored. On thefirst request of a stream, the host driver 220 may generate a state datacontrol block 270 which may include a stream state for the data streamand may exist for the life of the data stream according to anembodiment. For each request call, the host driver 220 may generate arequest block 280 with references to the stream state and theapplication's input buffer 250 and output buffer 260 according to anembodiment.

To begin processing the request, the compression accelerator 210 mayread the request block 280 according to an embodiment. The compressionaccelerator 210 of an embodiment may process the data in the inputbuffer 250 and may save the resulting inflated/deflated data in theoutput buffer 260. According to an embodiment, the compressionaccelerator 210 may also save an updated stream state when directed bythe host driver 220.

With reference to FIG. 3, a process 300 for managing the state of a datastream in a data stream interface according to an embodiment isgenerally shown. The data stream interface of an embodiment offloads theinflation/deflation processing of data to a stateless compressionaccelerator 210. According to an embodiment, the process 300 may beimplemented by the processing unit 16 of the computing system 10 shownin FIG. 1.

At block 310 of FIG. 3, the host driver 220 transmits a request to thecompression accelerator 210 to inflate/deflate a data stream accordingto an embodiment. Each transmitted request from the host driver 220 mayinclude references to the state data control block 270 and the inputbuffer 250 and the output buffer 260 of the host application 240according to an embodiment. The input buffer 250 of an embodimentincludes data to be processed by the compression accelerator 210. Theoutput buffer 260 of an embodiment is where the data processed by thecompression accelerator 210 may be stored. The state data control block270 of an embodiment includes stream state for the requested datastream.

At block 320, an embodiment determines whether the transmitted requestin block 310 is a first request for a data stream. On the first requestto the compression accelerator 210, the host driver 220 may generate astate data control block 270 according to an embodiment. The state datacontrol block 270 may exist for the life of the data stream according toan embodiment. Because the state data control block 270 is initiallyempty, the host driver 220 does not provide a stream state for the inputdata to the compression accelerator 210 on the first request, as shownin block 330. If, however, it is determined that the transmitted requestis not a first request for the data stream, the host driver 220 mayprovide the stream state from the previous request to the compressionaccelerator 210 according to an embodiment, as shown in block 340.According to an embodiment, the compression accelerator 210 may receivethe input stream state to bring the compression accelerator 210 back tothe state it was in after the last operation for the data stream.

At block 350, an embodiment determines whether the transmitted requestin block 310 is a final request for a data stream.

If the request is a final request for the data stream, the host driver220 instructs the compression accelerator 210 not to store the streamstate in the state data control block 270 after the request is completedaccording to an embodiment, as shown in block 360. To begin processingthe request, the compression accelerator 210 may read the request block280 received from the host driver 220 according to an embodiment.Accordingly, at block 370, the host driver 220 of an embodiment receivesthe processed data in the output buffer from the compression accelerator210.

If the request is not a final request for the data stream, however, thehost driver 220 instructs the compression accelerator 210 to store thestream state in the state data control block 270 after the request iscompleted according to an embodiment, as shown in block 380. Thecompression accelerator 210 of an embodiment may then process the datain the input buffer 250 and save the resulting inflated/deflated data inthe output buffer 260, as shown in block 390. As shown in block 390,when the compression accelerator 210 completes the request, thecompression accelerator 210 also transfers the current stream state backto the host's state data control block 270 according to an embodiment.

The DEFLATE compression algorithm introduces specific requirements onthe stream state of an embodiment. Two data structures that the DEFLATEalgorithm requires in the stream state of an embodiment are a dictionaryand Huffman Tree.

The DEFLATE algorithm uses a dictionary to find repeated strings in thedata to be deflated so a repeated string can be replaced by reference toan earlier occurrence of the string. The inflation process uses adictionary to replace these references with the actual string in theinflated data. The dictionary is a fixed size and is equivalent to thelast processed subset of data for that given fixed size. For deflatethis would be in input data and for inflate this would be the outputdata. In both the inflate and deflate cases, this dictionary is updatedas the stream is processed and may be part of the stream state of anembodiment.

The DEFLATE algorithm also uses a Huffman encoding technique. Huffmanencoding allows symbols to be replaced by codes of variable bit length.Shorter bit length codes are assigned to more frequently occurringsymbols. A symbol is either a byte in the data to be deflated or areference to a repeated string. The codes are called Huffman symbolcodes. The Huffman tree may represent this encoding according to anembodiment.

The Huffman encoding technique may also require an additional state tobe saved. The compression accelerator 210 of an embodiment reads andwrites full bytes from the application's buffers. However, the Huffmanencoding implies that deflated data is a bit stream without regard tobyte boundaries. For a stream being deflated, the last byte written tothe application's output buffer 260 may be only a partial Huffman symbolcode. The remaining bits of this Huffman symbol code must be saved inthe stream state of an embodiment so that these remaining bits can beadded to the output buffer 260 of the next request for the stream beforeany additional input data is processed. In the case of a stream beinginflated, the last bytes of the input buffer 250 may be a partialHuffman symbol code according to an embodiment. The bits that representthat partial Huffman symbol code must be save in the stream state of anembodiment so they can be used to create the entire Huffman symbol codewhen new input data becomes available with the next request for thestream.

Referring to FIG. 4, a flow diagram depicting a process 400 for buffermatching according to an embodiment is generally shown. According to anembodiment, the process 400 for buffer matching may be implemented bythe processing unit 16 of the computing system 10 shown in FIG. 1. Atblock 410, the space available in the output buffer 260 is monitoredafter each request according to an embodiment.

The amount of data processed by an individual request from the inputbuffer 250 is provided back to the host driver 220. This value is validin either the case where the output buffer 260 is completely full ornot.

In block 420, an embodiment determines whether the output buffer 260 isfull or not. Responsive to the output buffer 260 being completely fullon a return from an inflate/deflate request, the application 240 mayassume that not all of the input buffer 250 has been processed and maymake a new request with the same input buffer 250 with new output bufferspace, as shown in block 430. The input buffer 250 will begin processingat the last byte of unprocessed data by having the host driver 220manipulate the input buffer 250 to start at the correct point.

When the output buffer 260 is being returned not completely full onreturn from the inflate/deflate request, the application 240 may assumethat all data of the input buffer 250 has been processed and may submita subsequent request containing the next set of data in the stream to beinflated/deflated, as shown in block 440.

If there is room in the output buffer 260 when the compressionaccelerator 210 reaches the last group of bytes to process and the sizeof data produced by processing this last group of bytes is larger thanthe remaining space in the application's output buffer 260, thecompression accelerator 210 will still need to process the last group ofbytes. According to an embodiment, the compression accelerator 210 needsto process this last group of bytes since it must fill the application'soutput buffer 260 unless all the input data has been processed.

Referring to FIG. 5, a process 500 for handling overflow data duringdeflate processing according to an embodiment is shown. For deflateprocessing, the input bytes may be converted to Huffman Symbolsrepresenting either the bytes themselves or a length, distance pairingrepresenting a match in the dictionary, as shown in block 510. At block520, a determination is made as the whether the output buffer 260 wouldfit all the bits of the processed Huffman Symbols, according to anembodiment.

Responsive to determining that the output buffer 260 would fit all thebits of the processed Huffman Symbols, the processed Huffman Symbols arebit aligned and the compression accelerator 210 will insert all fullbytes into the output buffer 260, as shown in block 530. Otherwise,responsive to determining that the output buffer 260 will only fit asubset of the bits of the processed Huffman Symbols, the final byte,which only contains a subset of bits related to the output, will beprovided back in the stream state along with the count of bits which arepart of the output, as shown in block 340. According to an embodiment,it is the responsibility of the host driver 220 to provide state data tothe compression accelerator 210 on the next request. Accordingly, theseremaining bits can be added to the output buffer 260 of the next requestfor the stream before any additional input data is processed.

Referring to FIG. 6, a process 600 for handling overflow data duringinflate processing according to an embodiment is shown. For inflateprocessing, the compression accelerator 210 processes a group of HuffmanSymbols to be expanded, as shown in block 610. At block 620, adetermination is made as the whether the output buffer 260 would fit theresults from the inflate processing of the Huffman Symbols, according toan embodiment.

Responsive to determining that the output buffer 260 would fit all theresults from the inflate processing, the results are moved into theoutput buffer 260, as shown in block 630. According to an embodiment,the dictionary of the state data is updated as the stream is processed.

Responsive to determining that the output buffer 260 would only fit asubset of the results from the inflate processing, the compressionaccelerator 210 will fill the application's output buffer 260 with asmuch of the results from processing this group of bytes as fits, asshown in block 640. This value may be up to several hundred bytes for asingle Huffman Symbol as that is the longest length value allowed by theRFC minus one. According to an embodiment, the remaining results may besaved in the dictionary of the stream state along with a count of thenumber of bytes which are represented in the dictionary. According to anembodiment, the host driver 220 may move the remaining results to theapplication's output buffer 260 before the next request for the streamis sent to the compression accelerator 210.

During the next request processing of input buffer 250 will begin withsymbols which will resolve repeated string matching back into thedictionary. Since the extra output bytes have been placed into thedictionary this may be the required location for them in order for thecompression accelerator 210 to process the next request.

With respect to FIG. 7, a diagrammatic representation of a dictionary700 for a next request according to an embodiment is shown. Referring toFIG. 7, a last chunk of the input buffer 710, which does not fit afterbeing inflated into a previous output buffer, is saved as an overflow720 in the dictionary 700 along with pre-overflow dictionary data 730.Thus, according to an embodiment, the overflow data 720 stored in thedictionary 700 may be input to the next output buffer 740 during thenext request as discussed above.

Technical effects and benefits include providing a data stream interfacefor inflating/deflating data that can offload processing to a statelesscompression accelerator. Embodiments allow the inflated/deflated data tobe broken up across an arbitrary number of requests to the compressionaccelerator with no state kept between requests by the compressionaccelerator. Further, embodiments match the amount of input dataprocessed for one request to the amount of output buffer space providedby the application. Additionally, embodiments overcome issues arisingfrom the fact that data compressed in the DEFLATE format is a bit stringbut application input and output buffers are byte aligned. Embodimentsalso enable support for zlib compatible application interfaces toinflate/deflate data streams with the compression accelerator, thusallowing applications to exploit the compression accelerator with nocode changes. Given the wide use of zlib in applications requiringcompression services, embodiments significantly increase the value ofthe compression accelerator.

The terminology used herein is for the purpose of describing particularembodiments only and is not intended to be limiting of the disclosure.As used herein, the singular forms “a”, “an” and “the” are intended toinclude the plural forms as well, unless the context clearly indicatesotherwise. It will be further understood that the terms “comprises”and/or “comprising,” when used in this specification, specify thepresence of stated features, integers, steps, operations, elements,and/or components, but do not preclude the presence or addition of oneor more other features, integers, steps, operations, elements,components, and/or groups thereof.

The corresponding structures, materials, acts, and equivalents of allmeans or step plus function elements in the claims below are intended toinclude any structure, material, or act for performing the function incombination with other claimed elements as specifically claimed. Thedescription of the present disclosure has been presented for purposes ofillustration and description, but is not intended to be exhaustive orlimited to the disclosure in the form disclosed. Many modifications andvariations will be apparent to those of ordinary skill in the artwithout departing from the scope and spirit of the disclosure. Theembodiments were chosen and described in order to best explain theprinciples of the disclosure and the practical application, and toenable others of ordinary skill in the art to understand the disclosurefor various embodiments with various modifications as are suited to theparticular use contemplated.

Further, as will be appreciated by one skilled in the art, aspects ofthe present disclosure may be embodied as a system, method, or computerprogram product. Accordingly, aspects of the present disclosure may takethe form of an entirely hardware embodiment, an entirely softwareembodiment (including firmware, resident software, micro-code, etc.) oran embodiment combining software and hardware aspects that may allgenerally be referred to herein as a “circuit,” “module” or “system.”Furthermore, aspects of the present disclosure may take the form of acomputer program product embodied in one or more computer readablemedium(s) having computer readable program code embodied thereon.

Any combination of one or more computer readable medium(s) may beutilized. The computer readable medium may be a computer readable signalmedium or a computer readable storage medium. A computer readablestorage medium may be, for example, but not limited to, an electronic,magnetic, optical, electromagnetic, infrared, or semiconductor system,apparatus, or device, or any suitable combination of the foregoing. Morespecific examples (a non-exhaustive list) of the computer readablestorage medium would include the following: an electrical connectionhaving one or more wires, a portable computer diskette, a hard disk, arandom access memory (RAM), a read-only memory (ROM), an erasableprogrammable read-only memory (EPROM or Flash memory), an optical fiber,a portable compact disc read-only memory (CD-ROM), an optical storagedevice, a magnetic storage device, or any suitable combination of theforegoing. In the context of this document, a computer readable storagemedium may be any tangible medium that can contain, or store a programfor use by or in connection with an instruction execution system,apparatus, or device.

A computer readable signal medium may include a propagated data signalwith computer readable program code embodied therein, for example, inbaseband or as part of a carrier wave. Such a propagated signal may takeany of a variety of forms, including, but not limited to,electro-magnetic, optical, or any suitable combination thereof. Acomputer readable signal medium may be any computer readable medium thatis not a computer readable storage medium and that can communicate,propagate, or transport a program for use by or in connection with aninstruction execution system, apparatus, or device.

Program code embodied on a computer readable medium may be transmittedusing any appropriate medium, including but not limited to wireless,wireline, optical fiber cable, RF, etc., or any suitable combination ofthe foregoing.

Computer program code for carrying out operations for aspects of thepresent disclosure may be written in any combination of one or moreprogramming languages, including an object oriented programming languagesuch as Java, Smalltalk, C++ or the like and conventional proceduralprogramming languages, such as the “C” programming language or similarprogramming languages. The program code may execute entirely on theuser's computer, partly on the user's computer, as a stand-alonesoftware package, partly on the user's computer and partly on a remotecomputer or entirely on the remote computer or server. In the latterscenario, the remote computer may be connected to the user's computerthrough any type of network, including a local area network (LAN) or awide area network (WAN), or the connection may be made to an externalcomputer (for example, through the Internet using an Internet ServiceProvider).

Aspects of the present disclosure are described above with reference toflowchart illustrations and/or block diagrams of methods, apparatus(systems) and computer program products according to embodiments of thedisclosure. It will be understood that each block of the flowchartillustrations and/or block diagrams, and combinations of blocks in theflowchart illustrations and/or block diagrams, can be implemented bycomputer program instructions. These computer program instructions maybe provided to a processor of a general purpose computer, specialpurpose computer, or other programmable data processing apparatus toproduce a machine, such that the instructions, which execute via theprocessor of the computer or other programmable data processingapparatus, create means for implementing the functions/acts specified inthe flowchart and/or block diagram block or blocks.

These computer program instructions may also be stored in a computerreadable medium that can direct a computer, other programmable dataprocessing apparatus, or other devices to function in a particularmanner, such that the instructions stored in the computer readablemedium produce an article of manufacture including instructions whichimplement the function/act specified in the flowchart and/or blockdiagram block or blocks.

The computer program instructions may also be loaded onto a computer,other programmable data processing apparatus, or other devices to causea series of operational steps to be performed on the computer, otherprogrammable apparatus or other devices to produce a computerimplemented process such that the instructions which execute on thecomputer or other programmable apparatus provide processes forimplementing the functions/acts specified in the flowchart and/or blockdiagram block or blocks.

The flowchart and block diagrams in the Figures illustrate thearchitecture, functionality, and operation of possible implementationsof systems, methods, and computer program products according to variousembodiments of the present disclosure. In this regard, each block in theflowchart or block diagrams may represent a module, segment, or portionof code, which comprises one or more executable instructions forimplementing the specified logical function(s). It should also be notedthat, in some alternative implementations, the functions noted in theblock may occur out of the order noted in the figures. For example, twoblocks shown in succession may, in fact, be executed substantiallyconcurrently, or the blocks may sometimes be executed in the reverseorder, depending upon the functionality involved. It will also be notedthat each block of the block diagrams and/or flowchart illustration, andcombinations of blocks in the block diagrams and/or flowchartillustration, can be implemented by special purpose hardware-basedsystems that perform the specified functions or acts, or combinations ofspecial purpose hardware and computer instructions.

What is claimed is:
 1. A computer-implemented method, comprising:transmitting, by a processing device, a request to inflate or deflate adata stream to a compression accelerator, the request comprisingreferences to an input buffer for storing input data from the datastream, an output buffer for storing processed input data, and a statedata control block for storing a stream state; providing the streamstate to the compression accelerator to continue processing the datastream responsive to the request being a subsequent request; instructingthe compression accelerator to store a current stream state in the statedata control block responsive to the request being a non-final request;receiving the current stream state from the compression acceleratorresponsive to the request being a non-final request; and receiving theprocessed input data from the compression accelerator.
 2. Thecomputer-implemented method of claim 1, wherein the stream state isprovided to the compression accelerator beginning with a second request.3. The computer-implemented method of claim 1, further comprisinginstructing the compression accelerator not to store a current streamstate in the state data control block responsive to the request being afinal request.
 4. The computer-implemented method of claim 1, furthercomprising: monitoring an availability of space in the output bufferafter each request; issuing a request referencing a previous inputbuffer with new output buffer space responsive to the output bufferbeing full; and issuing a request referencing a next set of data fromthe data stream responsive to the output buffer having space.
 5. Thecomputer-implemented method of claim 1, wherein an overflow of deflateddata received from the compression accelerator is saved in the streamstate and added to the output buffer of a next request.
 6. Thecomputer-implemented method of claim 1, wherein an overflow of inflateddata received from the compression accelerator is saved in the streamstate and is used to create an entire Huffman code when new inputbecomes available with a next request.
 7. The computer-implementedmethod of claim 1, wherein the stream state comprises a dictionary and aHuffman Tree.
 8. A computer program product, comprising: a computerreadable storage medium having program code embodied therewith, theprogram code executable by a processor for: transmitting a request toinflate or deflate a data stream to a compression accelerator, therequest comprising references to an input buffer for storing input datafrom the data stream, an output buffer for storing processed input data,and a state data control block for storing a stream state; providing thestream state to the compression accelerator to continue processing thedata stream responsive to the request being a subsequent request;instructing the compression accelerator to store a current stream statein the state data control block responsive to the request being anon-final request; receiving the current stream state from thecompression accelerator responsive to the request being a non-finalrequest; and receiving the processed input data from the compressionaccelerator.
 9. The computer program product of claim 8, wherein thestream state is provided to the compression accelerator beginning with asecond request and the compression accelerator is instructed not tostore a current stream state in the state data control block responsiveto the request being a final request.
 10. The computer program productof claim 8, further comprising: monitoring an availability of space inthe output buffer after each request; issuing a request referencing aprevious input buffer with new output buffer space responsive to theoutput buffer being full; and issuing a request referencing a next setof data from the data stream responsive to the output buffer havingspace.
 11. The computer program product of claim 8, wherein an overflowof deflated data received from the compression accelerator is saved inthe stream state and added to the output buffer of a next request. 12.The computer program product of claim 8, wherein an overflow of inflateddata received from the compression accelerator is saved in the streamstate and is used to create an entire Huffman code when new inputbecomes available with a next request.
 13. The computer program productof claim 8, wherein the stream state comprises a dictionary and aHuffman Tree.